
<div>
  <h1>
    订单(<%= @orders.total_entries %>)
  </h1>
</div>

<div>
  <table class="table table-striped">
    <tr>
      <th>ID</th>
      <th>订单号</th>
      <th>类型</th>
      <th>状态</th>
      <th>总额</th>
      <th>创建时间</th>
      <th>操作</th>
    </tr>

    <% @orders.each do |order| %>
      <tr>
        <td><%= order.id %></td>
        <td><a href="<%= admin_order_path order %>"><%= order.order_no %></a></td>
        <td><%= order.order_type_i18n %></td>
        <td><%= order.state_label %></td>
        <td><%= order.total_money %></td>
        <td><%= order.created_at.to_s :db %></td>
        <td>
          <a href="<%= admin_order_path order %>">详情</a>
        </td>
      </tr>
    <% end -%>
  </table>

  <%= will_paginate @orders %>
</div>


